Voltage comparators are used in electronic systems to detect that a signal of interest has attained some predetermined value which is commonly referred to as the threshold level. When this event occurs the comparator produces a change in logic level at its output to indicate the threshold level has been attained. The threshold detection function of a voltage comparator is typically accomplished by electronically comparing the signal of interest to an externally supplied reference voltage.
An example of an application of a voltage comparator is the detection that a primary power supply voltage has exceeded specification limits, thereby warranting a corrective action of some sort, such as system shutdown. Another application is the detection of the presence or absence of a data transmission cable, through a bias voltage present in the cable when connected, to begin or halt data transmission or reception, or otherwise indicate the connection status of the cable.
The threshold detection function of a voltage comparator is typically accomplished by electronically comparing the signal of interest to an externally supplied reference voltage. The primary technical issues associated with the use of a voltage comparator are precision of the external reference power supply, accuracy of the electronic comparison, and power requirements of the included components. The complexity of the comparator implementation therefore varies between wide extremes depending upon the specific application and associated requirements. Moreover, setting and controlling the threshold level for the comparator is the main contributor to complexity and power consumption due to the necessity for a reference power supply that typically must remain powered on during system operation.
A further requirement of a comparator is that it must produce a change in logic state at its output that corresponds to the signal of interest having attained the threshold level in both positive and negative going directions. For example, if the comparator output is at a logic "1" when the signal of interest is below the threshold level, the output must change to a logic "0" and remain there when the threshold level is reached or exceeded. Also, for this example, the comparator output must change from a logic "0" to a logic "1" and remain there when the signal of interest falls below the threshold level.
Three examples of the prior art are now described, and serve to illustrate various degrees of complexity associated with setting a comparator threshold level. The detailed requirements of a specific application will directly determine the means by which the threshold level is to be set with possible tradeoffs between precision and power consumption.
The simplest approach to accomplishing the comparator function, though not commonly referred to as such, is through the use of a simple inverter as shown in FIG. 1. The signal of interest V.sub.IN is applied to the input of inverter 10, and upon reaching the threshold level of the input gate of a semiconductor device within the inverter 10, causes the output of inverter 10 to change logic states. The threshold level is determined by the particular device used to form the input gate, the power supply voltage, and operating temperature. This approach has very low power requirements, but does not provide a means of adjusting the threshold level. Nor does it provide the accuracy required of most comparator applications in determining that the threshold level has been reached.
FIG. 2 illustrates a differential comparator circuit wherein V.sub.OUT will change logic states when the signal of interest, Vin, equals or exceeds the threshold level, Vth. The threshold level for the comparator is established through use of an external precision reference power supply 14 as the second input to the comparator. This approach is often enhanced to achieve improved performance by adding circuitry for temperature compensation and reducing power supply drift, but with a penalty of increased power consumption and complexity.
FIG. 3 also shows a differential comparator, but with the addition of a digital to analog converter, ("DAC") 18, used in conjunction with an external reference supply 20 for setting the threshold level, Vth. The threshold level is set by means of a serial programming bus 22 to the DAC 18, and may be changed as the specific application or operating conditions may dictate. This approach offers substantially improved threshold level accuracy, but with increased power consumption and complexity, over that achievable with the examples described above.
It is readily seen from these examples of the prior art that the precision and adjustability requirements for setting a threshold level dictate the degree of circuit complexity and power consumption that are incurred in a particular application.